package com.atgm.mall.gmmallauth.feign;

import com.atgm.common.utils.R;
import com.atgm.common.vo.login.WeiboUser;
import com.atgm.mall.gmmallauth.feign.fallback.MemberFeignFallBackService;
import com.atgm.mall.gmmallauth.vo.UserLoginVo;
import com.atgm.mall.gmmallauth.vo.UserRegistVo;
import org.springframework.cloud.openfeign.FeignClient;
import org.springframework.web.bind.annotation.PostMapping;
import org.springframework.web.bind.annotation.RequestBody;

@FeignClient(value = "gm-mall-member", fallback = MemberFeignFallBackService.class)
public interface MemberFeignService {

    @PostMapping("/gmmallmember/member/register")
    public R register(@RequestBody UserRegistVo vo);

    @PostMapping(value = "/gmmallmember/member/login")
    public R login(@RequestBody UserLoginVo vo);

    @PostMapping("/gmmallmember/member/weiboLogin")
    R handlerWeiboLogin(@RequestBody WeiboUser weiboUser);

}
